<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<div id="app">

    <input type="button" value="一个按钮" v-on:click="show()">
    <input type="button" value="2th按钮" v-on:click="display1()">
    <!--    简化版本 -->
    <input type="button" value="3th按钮" @click="display2()">

</div>
<script src="js/vue.js"></script>
<script>
    //1.创建vue对象
    new Vue({
        el: "#app",
        data() { //简化书写
            return {
                username: "",
                url: "https://www.baidu.com"
            }
        },
        methods: {
            show() {
                alert("我被点击了....");
            },
            display1() {
                alert("我又被点击了......");
            },
            display2() {
                alert("我又又又被点击了......");
            }
        }
    });
</script>
</body>
</html>